home *** CD-ROM | disk | FTP | other *** search
- /* cvobj.c
- * object descriptions, etc.
- *************************************************************************/
-
- #include <stdio.h>
- #include "cvobj.h"
- #include "cvlocs.h"
-
- extern struct cvloc cvloc[];
-
- struct cvobj cvobj[] = {
-
- {""}, /* there's no object zero */
-
- {"several diamonds","There are diamonds here.\n",116},
-
- {"sack of silver","There is a sack of silver here.\n",109},
-
- {"precious jewelry","There is precious jewelry here.\n",123},
-
- {"rare coins","There are many coins here.\n",77},
-
- {"treasure chest","The pirate's treasure chest is here.\n"},
-
- {"ermine cape","There is an ermine cape here.\n",89},
-
- {"iron crown","There is a black, finely wrought iron crown here.\n",83},
-
- {"scepter","There is a jewel-encrusted scepter here.\n",110},
-
- {"fist-sized sapphire","There is a sapphire here the size of your fist.\n",
- 117},
-
- {"platinum orb","There is a platinum orb here, 6 inches in diameter.\n",114},
-
- {"jade idol","There is a small, exquisite jade idol here.\n~\
- A gigantic idol blocking the far end of the chamber is facing you.\n~\
- A convulsive groan fills the chamber, as the idol shatters explosively.\n\
- Flying shards strike and kill all of the orcs, and narrowly miss you!\n\
- All the orcs vanish in greasy black clouds of smoke.\n",
- 132,-1,1},
-
- {"persian rug","There is a persian rug spread out on the floor.\n~\
- You are hovering in the air, resting on a carpet.\n~\
- As you drop the carpet, it flies away, out of sight.\n",
- 126},
-
- {"jeweled collar","There is a jeweled collar here.\n~\
- There is a unicorn wearing a jeweled collar beside you.\n~\
- There is a unicorn wearing a jeweled collar nearby.\n~\
- The unicorn disappears as you touch it, but the collar drops to the floor!\n~\
- The unicorn shies away as you try to approach it.\n~\
- The unicorn gingerly approaches your corpse and gently touches you with\n\
- its horn. As it moves away, you begin to stir, slowly at first and\n\
- gradually return to life and to health!\n~\
- A soft glow from the unicorn's magic horn lights up the area.\n",
- 0,-1,2},
-
- {"golden chain","There is a golden chain lying in a heap on the floor.\n~\
- There is a golden chain locked to the wall.\n~\
- The bugbear is locked to the wall with a golden chain\n",
- 76,-1,2},
-
- {"ring of adamant","There is a ring of adamant here.\n",128},
-
- {"mithril helm","Near you is a small helmet made of mithril.\n~\
- The Fell King is striding after you!\n~\
- The tomb crumbles into dust. The graven figure on top rises. He is\n\
- stalking you, swinging the mace!\n~\
- The mace strikes the dragon, killing the poor thing.\n~\
- There is a massive iron tomb here. On top is a wrought figure of the\n\
- King...a fell figure of grim visage, wearing a mithril helm, and holding\n\
- a mace.\n~\
- The Fell King has caught up. His mace catches you across the head, and\n\
- you die!\n~\
- The Fell King disintegrates into a pile of dust, which rapidly blows away\n\
- His helm falls with a crash, and rolls to one side.\n",
- 83,-1,4},
-
- {"large gold nugget","There is a large sparkling nugget of gold here.\n",
- 60},
-
- {"throne","There is a large, bejeweled throne lying to one side.\n~\
- There is a large, bejeweled throne here.\n~\
- As you sit, you notice the inscription--\"Siege Perilous -- Nobles only.\"\n~\
- With a fearful roar, the throne hurls you straight up -- plastering you\n\
- on the roof of the cave!\n~\
- With a powerful roar, the throne hurls you straight up -- you narrowly\n\
- miss hitting the roof of the cave! Your fall jars every bone in your\n\
- body, but you find that you are all right.\n~\
- With a roar, the throne flips you into the air to land on the ground in\n\
- front of it.\n~\
- With a thump, the throne casts you on the ground in front of it.\n~\
- The throne silently tips over, revealing a hidden passage beneath it.\n\
- This is all that you have time to observe, as you are immediately trans-\n\
- ported, whirling giddily, throught a region of ominous vague shapes,\n\
- somber shadows, and sullenly-glowing lights! Finally landing with a \n\
- crash, you shake your head to clear it, look around, and discover . . .\n",
- 71,-1,1},
-
- {"sword","There is a jeweled sword here.\n",
- 68},
-
- {"hammer","There is a golden hammer head here.\n~\
- There is a heavy lead hammer here.\n~\
- The hammer shatters as it hits the skeleton.\n",
- 79,0,1},
-
- {"golden cup","There is a jeweled, golden cup here.\n~\
- There is a jeweled, golden cup full of water here.\n~\
- There is a jeweled, golden cup full of wine here.\n~\
- There is a jeweled, golden cup full of cola here.\n~\
- water in the cup\n~\
- wine in the cup\n~\
- cola in the cup\n~\
- The cup is now empty.\n~\
- The cup is now full of water.\n~\
- The cup is now full of wine.\n~\
- The cup is now full of cola.\n~\
- The cup was empty.\n~\
- The cup is already full.\n~\
- The bugbear is clutching the empty cup.\n",
- 72},
-
- {"ruby medallion","There is a ruby medallion here.\n",
- 83},
-
- {"parchment scroll","There is a parchment scroll here.\n",
- 75},
-
- {"ivory harp","There is a rare ivory harp here.\n~\
- A resounding chord rings through the room as you play.\n",
- 137},
-
- {"Philosopher's stone","The Philosopher's Stone is here.\n",
- 143},
-
- {"keg of beer","There is an intricately carved keg of beer here.\n~\
- There is a shattered beer keg here.\n",
- 73},
-
- {"long sword","There is a long sword here.\n",
- 150},
-
- {"broad sword","There is a broad sword here.\n",
- 150},
-
- {"spear","There is a spear here.\n",
- 150},
-
- {"short sword","There is a short sword here.\n",
- 150},
-
- {"bow","There is a bow here.\n",
- 150},
-
- {"dagger","There is a dagger here.\n",
- 150},
-
- {"quarterstaff","There is a quarterstaff here.\n",
- 150},
-
- {"halberd","There is a halberd here.\n",
- 150},
-
- {"armor","There is armor here.\n",
- 150},
-
- {"heater shield","There is a \"heater\" shield here.\n",
- 150},
-
- {"round shield","There is a round shield here.\n",
- 150},
-
- {"tall shield","There is a tall shield here.\n",
- 150},
-
- {"cuirass","There is a cuirass here.\n",
- 150},
-
- {"","There is a pure white column here.\n~\
- There is a scarred, beat up, muddy white column here.\n",
- 32,-1},
-
- {"","There are cave pearls here.\n~\
- There are the shattered remains of cave pearls here.\n",
- 46},
-
- {"","There are helictites on the walls.\n~\
- The ground is littered with broken helictites.\n",
- 49},
-
- {"","There are gypsum flowers here.\n~\
- There are the remains of shattered gypsum flowers here.\n",
- 47},
-
- {"","There are many cave bats here.\n~\
- Bodies of dead bats litter the ground.\n",
- 52},
-
- {"","There is a crystal butterfly here.\n~\
- There are shattered pieces of crystal here.\n",
- 42},
-
- {"","The ceiling is covered with soda-straw stalactites.\n~\
- The ground is covered with pieces of broken soda-straws.\n",
- 48},
-
- {"","There is an ancient indian pot here.\n~\
- The ground is covered with potshards.\n",
- 31},
-
- {""}, /* hole in sequence */
-
- {""}, /* hole in sequence */
-
- {"compass","A Boy Scout compass is lying nearby.\n",
- 1},
-
- {"set of keys","There are some keys on the ground here.\n",
- 2},
-
- {"brass lantern","There is a shiny brass lamp nearby.\n~\
- There is a lamp shining nearby.\n",
- 2},
-
- {"","Ranger Rick cautions you not to take or break anything in the cave.\n~\
- \"I told you not to take or break anything! Don't do it again!\"\n~\
- \"I warned you! Now you must leave the cave!\"\n~\
- \"Okay. I'm taking you to headquarters.\"\n~\
- \"I've had it with you. I'm locking you up.\"\n~\
- \"This time I'm going to throw away the key.\"\n~\
- Ranger Rick has been patrolling the cave in response to numerous com-\n\
- plaints of gate-crashers. You are the twelfth one he has caught today.\n\
- After escorting you out of the cave, he leaves you with a stern warning\n\
- not to take or break anything.\n",
- 30},
-
- {"Sears catalog","There is a Sears catalog here.\n~\
- The Sears catalog is lying at the bottom of the hole.\n",
- 4},
-
- {"your wallet","Your wallet is here, containing 1 dollar in change.\n~\
- Your wallet is here, containing 75 cents in change.\n~\
- Your wallet is here, containing 50 cents in change.\n~\
- Your wallet is here, containing 25 cents in change.\n~\
- Your empty wallet is here.\n",
- 2},
-
- {"","The cell door is locked.\n~\
- The cell door is standing open.\n",
- 21,-1,1},
-
- {"","There is a small bridge crossing the rapids.\n~\
- There is the wreckage of a small bridge here.\n",
- 33,35},
-
- {"You are in a small boat.","A small boat is tied here.\n~\
- A small boat is floating nearby.\n~\
- You are in a small boat tied here.\n~\
- You are afloat in a small boat.\n~\
- The wreckage of a small boat rests here.\n",
- 33},
-
- {"","There is a large rimstone dam here. Behind it, a pool of water\n\
- spills steadily over the dam. The ceiling dips into the pool.\n~\
- There is a broken rimstone dam here. The water level is the same on\n\
- both sides of the dam.\n",
- 37,60},
-
- {"","The gate is locked, and guarded by a Ranger. A sign says:\n\
- \"PAY RANGER FOR ADMISSION\".\n~\
- The gate opens easily from the inside. A sign says:\n\
- \"PERSONS LEAVING MUST RE-PAY TO REENTER\".\n~\
- The gate is jammed shut by debris.\n~\
- The gate is locked from the other side.\n",
- 30,31},
-
- /* ROPE */
- {"a coil of rope","There is a 120 foot coil of rope here.\n~\
- There is a 120 foot rope anchored here.\n~\
- There is a 60 foot coil of rope here.\n~\
- There is a 60 foot rope anchored here.\n~\
- There is a 120 foot coil of rope with a knot in the middle here.\n~\
- There is a 120 foot rope with a knot in the middle anchored here.\n~\
- There is a 120 foot coil of rope with a knot in the moddle here.\n~\
- There is a 120 foot rope with a knot in the middle anchored here.\n",
- 7},
-
- /* ROPE2 */
- {"a coil of rope","~\
- ~\
- There is a 60 foot coil of rope here.\n~\
- There is a 60 foot rope anchored here.\n"},
-
- /* EROPE */
- {"","The end of a rope dangles from above.\n~\
- A rope dangles from above, and falls below.\n~\
- A knotted rope dangles from above, and falls below.\n~\
- A rope dangles from above. About 60 feet of it lies on the ground,\n\
- not quite enough to reach the hole.\n~\
- A rope dangles from above. Some of it lies on the ground.\n",
- 0,-1},
-
- /* EROPE2 */
- {"","The end of a rope dangles from above.\n",
- 0,-1},
-
- {"","There is an immense pile of bat guano here.\n",
- 52,-1},
-
- {""}, /* hole in sequence */
-
- {"rare spices","There are rare spices here.\n",
- 88},
-
- {""}, /* knife */
-
- {"tasty food","There is food here.\n",
- 74},
-
- {"small bottle","There is an empty bottle here.\n~\
- There is a bottle of water here.\n~\
- There is a bottle of wine here.\n~\
- There is a bottle of cola here.\n~\
- water in the bottle\n~\
- wine in the bottle\n~\
- cola in the bottle\n~\
- The bottle is now empty.\n~\
- The bottle is now full of water.\n~\
- The bottle is now full of wine.\n~\
- The bottle is now full of cola.\n~\
- The bottle was empty.\n~\
- The bottle is already full.\n~\
- The bugbear is clutching the empty bottle.\n",
- 0,0,3},
-
- {""}, /* water */
-
- {""}, /* wine */
-
- {""}, /* cola */
-
- {"","There is a vacant mirror against the wall.\n~\
- Your reflection peers back at you from a mirror on the wall.\n~\
- As you step out the door, your image also steps from the mirror, and\n\
- follows you! Armed and armored exactly as you, *YOU* are your exact\n\
- match, except that your good nature is reflected as *YOUR* evil nature.\n\
- *YOU* will kill you, unless you destroy *YOURSELF* first.\n~\
- The mirror shatters explosively, destroying *YOU*! You are thrown\n\
- backward, throught the dorr, into the arena, where your screaming fans\n\
- flock down around you, pick you up, and carry you off to a month-long\n\
- revel honoring the glorious cave conqueror. . .\n~\
- The mirror shatters explosively, destroying you and all the cave.\n",
- 150,-1,1},
-
- {"","The half-disolved corpse of the giant orc is floating here in the acid\n\
- sea.\n~\
- The giant, angry orc is coming after you!\n~\
- A gigantic orc priest stands before the idol, and says:\n\
- \"You would be well off to make an offering to out idol!\"\n~\
- He easily snatches the axe from the air, examines it, laughs nastily,\n\
- and throws it back. He's very good at this, and he gets you.\n~\
- The giant orc stumbles into the acid sea, and screams in agony as the\n\
- waters attack him, boiling furiously, and raising great clouds of reeking\n\
- fumes.\n",
- 132,-1,2},
-
- {"","There is a pile of greasy, black rubble here.\n~\
- The galleries are lined with orcs, silently watching you.\n~\
- The orcs chant \"That is not the real thing\", and throw offal.\n~\
- The orcs scream \"AAIIEEE - - - 'ORCA-COLA'.\
- IT IS THE REAL THING!!!\"\n",
- 132,-1,1},
-
- {"","",
- 0,-1}, /* tomb */
-
- {"dwarf's axe","There is a little axe here.\n~\
- There is a little axe lying beside the bugbear.\n"},
-
- {"","There is a small, flat very ugly toad sitting here.\n~\
- As you touch the toad, it starts to swell and shange shape. It's --\n\
- it's -- it's turning into a dwarf princes! She -- she -- she's --\n\
- she's -- UGLY!\n\
- -- VERY UGLY!!!!!!\n\
- She's 3'6\" tall, and 180 lbs., with black, oily, snarly hair, and three\n\
- large warts on her nose, which separates two beady red eyes that don't\n\
- track. She immediately starts to say, in a high-pitched nasal whine,\n\
- \"Trying to pick me up, eh sweetie? Where do you think you get off? I'm\n\
- a decent broad, and won't have any of this. Whatcha doing around here?\n\
- You one of those weird explorers who rip off decent folks, taking their\n\
- treasures out of the cave? I hope you haven't found the vault yet . . .\"\n\
- \n\
- A cloud of white smoke and a wizard appear. He is garbed in green and\n\
- violet robes, and says \"I really must apologize about this. She has no\n\
- business in this game; she escaped from another game in the next town.\n\
- There really is no vault in this cave...she's referring to the next cave.\n\
- Sorry again.\" With that, he takes her hand, and they start to vanish.\n\
- As they fade out of sight, you note that she has taken his hat, and is\n\
- beating him severely about the ears with it.\n",
- 133},
-
- {"turqoise sand","There is turquoise sand here.\n~\
- The sand spreads out into a fine, stinging cloud.\n",
- 140},
-
- {"","You are standing on a thin shelf of rock jutting out from the side\n\
- of the windshaft.\n~\
- You are standing on a thin shelf of rock jutting out from the side of the\n\
- windshaft. Be careful, there are some cracks in the shelf!\n~\
- There are some loose rocks here indicative of a recent rock slide.\n",
- 130,-1},
-
- {"","The hangings look expensive, but very delicate.\n~\
- Okay, but ... ooops, how clumsy of me! Lucky there's no Ranger down here!\n~\
- The silk hangings are in tatters.\n~\
- The shreds of silk are not worth bothering with.\n",
- 126},
-
- {""}, /* 83: hole in sequence */
-
- {""}, /* 84: hole in sequence */
-
- {""}, /* 85: hole in sequence */
-
- {"","There is a large mound of pig droppings here.\n~\
- There is a large mound of pig droppings here, with footprints.\n",
- 9,-1},
-
- {"","There is a shower here.\n~\
- You are soaking wet, but much cleaner.\n",
- 2,-1},
-
- {"","There is a cola machine in one corner. The instructions read:\n\
- \"DROP CHANGE HERE TO GET A COLA.\"\n~\
- There is an empty cola machine in one corner.\n",
- 2,-1},
-
- {"batteries","There are fresh batteries here..\n~\
- Some worn-out batteries have been discarded nearby.\n",
- 119},
-
- {"","",
- 0,-1}, /* dwarf */
-
- {"","There is a drunken bugbear snoring loudly in one corner.\n~\
- There is a well-fed bugbear attacking you!\n~\
- There is a bugbear attacking you!\n~\
- There is a ferocious, well-fed bugbear at the far end of the room.\n~\
- There is a ferocious bugbear at the far end of the room.\n",
- 76,-1,4},
-
- {"","\There is a pile of broken bones here, with a rusty, broken cutlass\n\
- nearby.\n~\
- There is an animated skeleton circling around you, waving a cutlass!\n~\
- A skeleton is here, clutching a cutlass.\n",
- 87,-1,2},
-
- {"","The corpse of a giant hairy spider lies to one side.\n~\
- A giant hairy spider is following you, trying to get you!\n~\
- A giant hairy spider, named \"Grendl\", drops from the ceiling, barely\n\
- missing you. It starts to chase you around the room, trying to get you!\n",
- 0,-1,2},
-
- {"","The body of a small white dragon lies nearby.\n~\
- A small, white, fierce fire-breathing dragon lies on guard here.\n~\
- You are being followed by a dragon, who whines \"I'm hungry.\"\n~\
- A dragon follows you, whimpering \"Can I have a match, boss?\"\n~\
- A dragon follows you, whining \"I want my treasure back.\"\n~\
- There is a dragon beside you grumbling \"Can't we stop and rest?\"\n~\
- There is a dragon beside you, sniveling \"I want to go home.\"\n~\
- The small dragon complains \"I don't like this place.\"\n~\
- The small dragon wails \"Can I have some treasure, too?\"\n~\
- \"Woe is me,\" wails the small dragon.\n",
- 110,-1,1},
-
- {"","There is a djinni in the room with you.\n",
- 0,-1},
-
- {"","There is a kobold in the room with you.\n~\
- A knife is thrown at you...which misses!\n~\
- A knife is thrown at you...which gets you!\n~\
- A black cloud of smoke lingers here.\n",
- 0,-1},
-
- {"","The foul, stinking corpse of a balrog lies here.\n~\
- Stricken, and taken off guard, the balrog stumbles back. . .back. . .\n\
- and falls over the edge. . .down. . .down. . .down. . .and vanishes\n\
- into the gloom.\n~\
- There is a loathsome balrog here.\n~\
- The balrog grasps blindly for you!\n~\
- He hits your lamp shorting out the batteries and draining 90% of their\n\
- remaining life. Best do something before you run out of light!\n",
- 0,-1,2},
-
- {"","*YOU* are circling yourself warily, looking for an opening to attack.\n~\
- *YOU* easily parry your attack, and successfully attack in return,\n\
- you! You have died!!!\n~\
- *YOU* attack you, but you parry *YOUR* attack, and attack unsuccessfully\n\
- in return.\n~\
- Simultaneously, both you and *YOU* throw and handful of sand into each\n\
- other's eyes, accomplishing nothing.\n~\
- Expecting and attack, you and *YOU* retreat from each other, then come\n\
- back and clash, fruitlessly.\n",
- 0,-1},
-
- {NULL,NULL}
- };
-
- #include <string.h>
-
- extern void encode();
-
- void checkobj() {
- register int i, c;
- for (i=1; cvobj[i].desc != NULL; i++)
- { register char *p, *s;
- p = cvobj[i].props;
- if ( p != NULL && *(p) != '\0' &&
- *(p+strlen(p)-1) != '\n')
- (void) printf("obj %d cvobj: \n%s\n",i,p);
-
- encode(cvobj[i].desc);
-
- s = p;
- for (c=0; p[c]; c++) {
- if (p[c] == '~') {
- p[c] = '\0';
- encode(s);
- s = &(p[c+1]);
- }
- }
- encode(s);
- }
- };
-